Open the History palette
F9
Start/Stop Recording Command
Control+Shift+X
Command+Shift+X
Play Recorded Command
Control+P
Command+P